#if !defined(_STACK_H_)
#define _STACK_H_

typedef void* pointer;

typedef struct _stack
{
	pointer* data;
	size_t current;
	size_t start_size;
	size_t size;
	size_t increment;
} stack;

void stack_create(stack *pstack);

void stack_push(stack *pstack, pointer value);

void stack_destroy(stack *pstack);

size_t stack_size(stack *pstack);

pointer stack_pop(stack *pstack);

pointer stack_peek(stack *pstack);

void stack_tune(stack *pstack, size_t initial_size, size_t increment);

#endif